function userLoginForm(){
   	var flag=true;
	 var phoneno = /^\d{10}$/;  
	var phonenumber=$('#phoneNumber').val();
	if(phonenumber==""){
		$('#phoneNumberError').html("Required");
		flag=false;
	}else if(isNaN(phonenumber)){
		$('#phoneNumberError').html("Enter numbers only");
		flag=false;
	}else if(!phonenumber.match(phoneno)){
		$('#phoneNumberError').html("Invalid phonenumber");
		flag=false;
	}else{
		$('#phoneNumberError').html('');
	}
	if(flag==true){
		$('#indexLoader').html('<img src="images/ajax-loader.gif"/>');
		var deviceId="007007";
		var lat="17.506024";
		var longt="78.416671";
		var platform="Android";
		$.ajax({
			type		:	'POST',
			url			:  	webServiceUrl+'registration',
			dataType	: 	"json",
			data		:	{phonenumber:phonenumber,deviceID:deviceId,latitude:lat,longitude:longt,platform:platform},
			success: function(data){
				$('#indexLoader').html('');
				if(data.value==1){
					localStorage.setItem( 'user_id', JSON.stringify(data.user_id));		
					localStorage.setItem( 'rating', JSON.stringify(data.rating));		
					localStorage.setItem( 'radius', JSON.stringify(data.radius));		
					localStorage.setItem( 'setting_rating', JSON.stringify(data.setting_rating));		
					localStorage.setItem( 'phone', JSON.stringify(phonenumber));		
					localStorage.setItem( 'pincode', JSON.stringify(data.pincode));		
					window.location="profile.html";
				}
			}
		});
	}
}
/*
function updateUserName(){
    var flag=true;
	var charactervalidation = /^[a-zA-Z\s]*$/;
	var userName=$('#userName').val();
	if(userName==""){
	   $("#userNameError").html("Required");
	   flag=false;   
	}else if(!userName.match(charactervalidation)){
		$("#userNameError").html("Enter only characters");
		flag=false; 
	}else{
		$("#userNameError").html(""); 
	}
	if(flag==true){
		var user_id = JSON.parse(localStorage["user_id"]);
	   $.ajax({
			type		:	'PUT',
			url			:  	webServiceUrl+'registration/'+user_id,
			dataType	: 	"json",
			data		:	{username:userName},
			success: function(data){}
		});
	}
}

function updateUserAddress(){
    var flag=true;
	var userAddress=$('#userAddress').val();
	if(userAddress==""){
	   $("#userAddressError").html("Required");
	   flag=false;   
	}else{
		$("#userAddressError").html(""); 
	}
	if(flag==true){
		var user_id = JSON.parse(localStorage["user_id"]);
	   $.ajax({
			type		:	'PUT',
			url			:  	webServiceUrl+'registration/'+user_id,
			dataType	: 	"json",
			data		:	{useraddress:userAddress},
			success: function(data){}
		});
	}
}
*/
function updateSettings(){
	$('#indexLoader').html('<img src="images/ajax-loader.gif"/>');
	var flag=true;
	settingrating=$('#setting_rating').val();
	radius=$('#radius').val();
	if($("#cmn-toggle-1").prop('checked') == true){
		available_status=0;
	}else{
		available_status=1;
	}
	if($("#cmn-toggle-2").prop('checked') == true){
		notifications_status=0;
	}else{
		notifications_status=1;
	}
	if(settingrating==""){
	   $("#ratingError").html("Required");
	   flag=false;   
	}else{
		$("#ratingError").html(""); 
	}
	if(radius==""){
	   $("#radiusError").html("Required");
	   flag=false;   
	}else{
		$("#radiusError").html(""); 
	}
	if(flag==true){
		var user_id = JSON.parse(localStorage["user_id"]);
		$.ajax({
			type		:	'PUT',
			url			:  	webServiceUrl+'update_user_settings/'+user_id,
			dataType	: 	"json",
			data		:	{type:'setting',available_status:available_status,notifications_status:notifications_status,radius:radius,settingrating:settingrating},
			success: function(data){
				$('#indexLoader').html('');
				localStorage.setItem( 'radius', JSON.stringify($('#radius').val()));
				localStorage.setItem( 'setting_rating', JSON.stringify($('#setting_rating').val()));
				$('#sucessMessage').show().delay(2000).fadeOut();
				if(go_list_value==1){
					window.location="view-list.html";
				}
			}
		});
	}else{
		$('#indexLoader').html('');
	}
}

function updateUserProfile(){
	$('#indexLoader').html('<img src="images/ajax-loader.gif"/>');
    var flag=true;
	var charactervalidation = /^[a-zA-Z\s]*$/;
	var userName=$('#userName').val();
	var userAddress=$('#userAddress').val();
	var rating=$('#rating').val();
	var userPincode=$('#userPincode').val();
	if(userName==""){
	   $("#userNameError").html("Required");
	   flag=false;   
	}else if(!userName.match(charactervalidation)){
		$("#userNameError").html("Enter only characters");
		flag=false; 
	}else{
		$("#userNameError").html(""); 
	}
	if(userAddress==""){
	   $("#userAddressError").html("Required");
	   flag=false;   
	}else{
		$("#userAddressError").html(""); 
	}
	if(userPincode==""){
	   $("#userPincodeError").html("Required");
	   flag=false;   
	}else{
		if (userPincode == parseInt(userPincode, 10)){
			$("#userPincodeError").html(""); 
		}else{
			$("#userPincodeError").html("Numbers only");
			flag=false; 
		}
	}
	if(rating==""){
	   $("#ratingError").html("Required");
	   flag=false;   
	}else{
		$("#ratingError").html(""); 
	}
	if(flag==true){
		var user_id = JSON.parse(localStorage["user_id"]);
		var radius = JSON.parse(localStorage["radius"]);
	   $.ajax({
			type		:	'PUT',
			url			:  	webServiceUrl+'registration/'+user_id,
			dataType	: 	"json",
			data		:	{userName:userName,userPincode:userPincode,userAddress:userAddress,rating:rating,type:'rating'},
			success: function(data){
				$('#indexLoader').html('');
				localStorage.setItem( 'pincode', JSON.stringify(userPincode));	
				localStorage.setItem( 'rating', JSON.stringify(rating));	
				$('#sucessMessage').show().delay(2000).fadeOut();
				if(radius==0){
					window.location="settings.html";
				}
			}
		});
	}else{
		$('#indexLoader').html('');
	}
}
function userPost(){
	var flag=true;
	var message=$('#message').val();
	//var venue=$('#venue').val();
	var streatAddress=$('#streetAddress').val();
	var city=$('#city').val();	
	var zipcode=$('#zipcode').val();	
	//var input_prop_date=$('#input_prop_date').val();
	//var input_prop_time=$('#input_prop_time').val();
	//var input_until_date=$('#input_until_date').val();
	//var input_until_time=$('#input_until_time').val();
	//New Functionality
	var input_prop_date=$('#ProposedDate').val();
	/*if(input_prop_date){
	var change_input_prop_date = input_prop_date.split(' ');
	var change_date=change_input_prop_date[0].split('/');
	var praposedDate=change_date[1]+'/'+change_date[2]+'/'+change_date[0];
	var change_time = change_input_prop_date[1].split(':');
	//alert(change_input_prop_date[0]+'---'+change_input_prop_date[1]);
	var hours = change_time[0];
        var min = change_time[1];
        if (hours < 12) {
           var proposedTime= hours + ':' + min + ' AM';
        } else {
            hours=hours - 12;
            hours=(hours.length < 10) ? '0'+hours:hours;
           proposedTime= hours+ ':' + min + ' PM';
		    
        }
	}*/	
	var input_until_date=$('#untilDate').val();
	/*if(input_until_date){
	var change_input_until_date = input_until_date.split(' ');
	var change_Udate=change_input_until_date[0].split('/');
	var untilDate=change_Udate[1]+'/'+change_Udate[2]+'/'+change_Udate[0];
	var change_utime = change_input_until_date[1].split(':');
	var uhours = change_utime[0];
        var umin = change_utime[1];
        if (uhours < 12) {
           var untilTime= uhours + ':' +umin + ' AM';
        } else {
            uhours=uhours - 12;
            uhours=(uhours.length < 10) ? '0'+uhours:uhours;
			untilTime= uhours+ ':' + umin + ' PM';
		   
        }
	}*/	
	//End	
	if(message==""){
		$('#messageError').html('Required');
		var flag=false;
	}else{
		$('#messageError').html('');
	}
	/*if(venue==""){
		$('#venueError').html('Required');
		var flag=false;
	}else{
		$('#venueError').html('');
	}*/
	if(city==""){
		$('#cityError').html('Required');
		var flag=false;
	}else{
		$('#cityError').html('');
	}
	if(zipcode==""){
		$('#zipcodeError').html('Required');
		var flag=false;
	}else if(isNaN(zipcode)){
		$('#zipcodeError').html('Numbers Only');
		var flag=false;
	}else{
		$('#zipcodeError').html('');
	}
	if(streatAddress==""){
		$('#streataddressError').html('Required');
		var flag=false;
	}else{
		$('#streataddressError').html('');
	}
	if(input_prop_date==""){
		$('#ProposedDateError').html('Required');
		var flag=false;
	}else{
		$('#ProposedDateError').html('');
	}
	/*if(input_prop_time==""){
		$('#ProposedDateError').html('Required');
		var flag=false;
	}else{
		$('#ProposedDateError').html('');
	}*/
	
	if(input_until_date==""){
		$('#untilDateError').html('Required');
		var flag=false;
	}else if(input_prop_date>=input_until_date){
		$('#untilDateError').html('Please Select correct until date and time');
		var flag=false;
	}else{
		$('#untilDateError').html('');
	}
	/*if(input_until_time==""){
		$('#untilDateError').html('Required');
		var flag=false;
	}else{
		$('#untilDateError').html('');
	}
	
	if(input_prop_date>=input_until_date){
		
		$('#untilDateError').html('Please Select correct until date and time');
		var flag=false;
	}else{
		$('#untilDateError').html('');
	}*/		
	if(flag==true){
		$('#inviteLoader').html('<img src="images/ajax-loader.gif"/>');
		//var proposedDate=convertDateFormate(input_prop_date)+' '+input_prop_time;
		//var proDate=praposedDate+' '+proposedTime;
		//var untilDate=convertDateFormate(input_until_date)+' '+input_until_time;
		//var untDate=untilDate+' '+untilTime;
		var venueDetailes=streatAddress+','+city+','+zipcode;
		//alert(venueDetailes);return false;
		//alert(proDate +'--'+ untDate); 
		var user_id = JSON.parse(localStorage["user_id"]);
		var rating  = JSON.parse(localStorage["rating"]);
		var settingrating  = JSON.parse(localStorage["setting_rating"]);
		var radius = JSON.parse(localStorage["radius"]);
		var pincode = JSON.parse(localStorage["pincode"]);
		$.ajax({
			type		:	'POST',
			url			:  	webServiceUrl+'add_post',
			dataType	: 	"json",
			data		:	{ message:message,venue:venueDetailes,proposeddate:input_prop_date,user_id:user_id,untildate:input_until_date,rating:rating,settingrating:settingrating,radius:radius,pincode:pincode },
			success: function(data){
				$('#inviteLoader').html('');
				window.location="viewalert.html";
			}
		});
	}
}

function convertDateFormate(str){
	var arr = str.split(' ');
	var months = ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'];
	var i = 0; 
	for (i; i <= (months.length-1); i++) {
	  var monthName=arr[1].substring(0, arr[1].length - 1);
	  if (months[i] == monthName)
	   {  
		break;
	   } 
	}
	var formatddate = (i+1)  + '/' + arr[0] + '/' + arr[2];
	return formatddate;
	
}
//viewAlerts

function openPopup(replyId,user_post_id,partner_id){
$('#partner_name').val($('#partnerName'+replyId).val());
$('#user_post_id').val(user_post_id);
$('#replier_id').val(replyId);
$('#partner_id').val(partner_id);
$('#p_platform').val($('#pat_platform'+user_post_id).val());
$('#pop-up-1').popUpWindow({action: "open"});
}


function closePopup(){
	$('#user_post_id').val('0');
	$('#replier_id').val('0');
	$('#pop-up-1').popUpWindow({action: "close"});
}
function confirmPartner(){
var user_post_replies_id =$('#replier_id').val();
var user_post_id    	 =$('#user_post_id').val();
var partner_id      	 =$('#partner_id').val();
var partner_platform	 =$('#p_platform').val();
var deviceID=$('#deviceID'+user_post_id).html();
var p_time=$('#p_time'+user_post_id).html();
var u_time=$('#u_time'+user_post_id).html();
//alert(p_time+'---'+u_time);return false;
	$.ajax({
		type		:	'PUT',
		url			:  	webServiceUrl+'get_alerts/'+user_post_replies_id,
		dataType	: 	"json",
		data		: 	{ status:1,user_post_id:user_post_id,deviceID:deviceID,partner_id:partner_id,partner_platform:partner_platform },
		success: function(data){
			window.location="confirmation-alerts.html?id="+user_post_replies_id;
		}
	});
}		
//get time format 
function convertMysqldate(dateStr) {   
	var t = dateStr.split(/[- :]/);
	var monthNames = ["01", "02", "03", "04", "05", "06","07", "08", "09", "10", "11", "12"];
	var year = t[0];
	var month = monthNames[parseInt(t[1]-1)];
	var day = t[2];
	var hourTmp = t[3];
	var minute = t[4];
	var seconds = t[5];
	if (parseInt(hourTmp)>12) {
		var hour = parseInt(parseInt(hourTmp) - 12) + ':' + minute +' PM';
	} else if (parseInt(hourTmp) === 12) {
		hour = parseInt(hourTmp) + ':' + minute + ' PM';
	} else {
	   hour = parseInt(hourTmp) + ':' + minute + ' AM';
	}
	return (month +'/' + day +'/' + year +  ' ' +hour);
}
//reply partner
function replyPartner(){
var user_id = JSON.parse(localStorage["user_id"]);
var user_post_id=$('#user_post_id').val();
var deviceID=$('#deviceID'+user_post_id).html();
var partnerId=$('#replier_id').val();
var platform=$('#platform').val();
var p_time=$('#p_time'+user_post_id).html();
var u_time=$('#u_time'+user_post_id).html();
//alert(p_time+'---'+u_time); return false;
$.ajax({
		type		:	'POST',
		url			:  	webServiceUrl+'get_lists',
		dataType	: 	"json",
		data		: 	{user_post_id:user_post_id,partner_id:partnerId,user_id:user_id,deviceID:deviceID,platform:platform},
		success: function(data){
			if(data.value==1){
				$('#pop-up-1').popUpWindow({action: "close"});
				$('#red'+user_post_id).html('<a id="open-pop-up-2'+user_post_id+'" href="javascript:void(0);" ><div class="conform_btn_red"><p>&#10004;</p></div></a>');
			}
		}
	});
}

//Search Functionality

function searchFunction(){
	var valueHid=$('#searchHid').val();
	if(valueHid==0){
		$('#search').show();
		$('#searchHid').val(1);
		$('#wrapper').css('top','40%');
	}else{
		$('#search').hide();
		$('#searchHid').val(0);
	}
	
}
function searchInputFiledsFun(type){
	var flag=true;
	var search=$('#searchInputFields').val();
	if(search==""){
		$('#searchError').html('Required');
		flag=false;
	}else{
		$('#searchError').html('');
	}
	if(flag==true){
	var user_id = JSON.parse(localStorage["user_id"]);
	$('#notificationLoader').html('<img src="images/ajax-loader.gif"/>');
		$.ajax({
			type		:	'POST',
			url			:  	webServiceUrl+'search',
			dataType	: 	"json",
			data		: 	{ search:search,user_id:user_id, type:type},
			success: function(data){
				if(data.value==1){
					$('#notificationLoader').html('');
					var serchtodaylists="";
					var confirmation_pop_up="";
					var view_partner_detailes="";
					var obj = eval("(" + data.searchLists + ")");
						$.each(obj, function (index,serchList){
							var serchuserName=serchList.user_name;
							serchuserName = serchuserName.toLowerCase().replace(/\b[a-z]/g, function(letter) {
								return letter.toUpperCase();
							});
							var serchproposed_date_time=convertMysqldate(serchList.proposed_date_time);
							var serchuntil_date_time=convertMysqldate(serchList.until_date_time);
							serchtodaylists+='<input type="hidden" id="partnerName'+serchList.user_post_id+'" name="partnerName'+serchList.user_post_id+'" value="'+serchuserName+'">';
							serchtodaylists+='<div id="today-post'+serchList.user_post_id+'">'+
							'<div class="viewlist_pad">'+
								'<div class="pos_relative">'+
									'<div class="view_list"><p>'+serchList.phone+' <a href="javascript:void(0);" onclick="serchPDetailes('+serchList.user_post_id+')">'+serchuserName+'</a></p>'+
									'<p>'+serchList.pincode+' '+serchList.address+'</p>'+
									'<p>'+serchproposed_date_time+' To  '+serchuntil_date_time+'</p></div>'+
									'<div class="arrow1"></div>'+
									'<div class="arrow"></div>';
									if(serchList.upastatus==0){
									serchtodaylists+='<a id="open-pop-up-2'+serchList.user_post_id+'" href="javascript:void(0)"><div class="conform_btn_red"><p>&#10004;</p></div></a>';
									}else if(serchList.upastatus==1){
										serchtodaylists+='<a id="open-pop-up-2'+serchList.user_post_id+'" href="javascript:void(0)"><div class="conform_btn"><p>&#10004;</p></div></a><p style="display:none" id="p_time'+serchList.user_post_id+'">'+serchproposed_date_time+'</p><p style="display:none" id="u_time'+serchList.user_post_id+'">'+serchuntil_date_time+'</p>';
									}else{
										serchtodaylists+='<div id="red'+serchList.user_post_id+'"><a id="open-pop-up-2'+serchList.user_post_id+'" href="#pop-up-1" onclick="openPopupV('+serchList.user_post_id+','+serchList.user_id+')"><div class="conform_btn_blue"><p>&#10004;</p></div></a></div>'+
										'<p style="display:none" id="deviceID'+serchList.user_post_id+'">'+serchList.device_id+'</p>'+'<input type="hidden" id="p_platform'+serchList.user_post_id+'" value="'+serchList.platform+'"/><p style="display:none" id="p_time'+serchList.user_post_id+'">'+serchproposed_date_time+'</p><p style="display:none" id="u_time'+serchList.user_post_id+'">'+serchuntil_date_time+'</p>';
										
									}
									if(serchList.confirm_status==1){
										var postIds=$("#hid_post_id").val();
										$("#hid_post_id").val(postIds+','+serchList.user_post_id);
									}
									serchtodaylists+='</div>'+
								'</div>'+
							'</div>';
							view_partner_detailes+='<div id="serchpatid'+serchList.user_post_id+'" class="popup_text">'+
							'<p><h4>Partner Detailes</h4></p>'+ 
							'<div class="input_field input_popup_t">'+
								'<table><tr><td>PartnerName</td><td>:</td><td>'+serchuserName+'</td></tr>' +
								'<tr><td>PhoneNumber</td><td>:</td><td>'+serchList.phone+'</td></tr>' +
								'<tr><td>Address</td><td>:</td><td>'+serchList.address+'</td></tr>' +
								'<tr><td>pincode</td><td>:</td><td>'+serchList.pincode+'</td></tr>' +
								'<tr><td>Proposed date</td><td>:</td><td>'+serchproposed_date_time+'</td></tr>' +
								'<tr><td>Until date</td><td>:</td><td>'+serchuntil_date_time+'</td></tr></table>' +
							'</div>'+
							'</div>';
							confirmation_pop_up+='<div id="confirm'+serchList.user_post_id+'" class="popup_text">'+
							'<p><h4>Your request is confirmed.</h4></p>'+ 
							'<div class="input_field input_popup_t">'+
								'<table><tr><td>PartnerName</td><td>:</td><td>'+serchuserName+'</td></tr>' +
								'<tr><td>Contact no</td><td>:</td><td>'+serchList.phone+'</td></tr>' +
								'<tr><td>Proposed date</td><td>:</td><td>'+serchproposed_date_time+'</td></tr>' +
								'<tr><td>Until date</td><td>:</td><td>'+serchuntil_date_time+'</td></tr></table>' +
							'</div>'+
							'<div class="popup_btns" >'+
							'<div class="popup_row">'+
								'<a href="javascript:void(0);"><div class="ok" onclick="changeStatusConfirm('+serchList.user_post_replies_id+','+serchList.user_post_id+')">Ok</div></a>'+
							'</div>'+
								'<div class="clearfix"></div>'+
							'</div>'+
						'</div>';
						});
						$("#today_lists").html("");
						$('#today_posts').html(serchtodaylists);				
						$('#serchpartner_detailes').html(view_partner_detailes);
						$('#c_detailes').html(confirmation_pop_up);
						var postIds=$("#hid_post_id").val();
						if(postIds!=0){
							var allIds=postIds.split(',');
							for(var i=1;i<=(allIds.length)-1;i++){
								$('#confirm'+allIds[i]).popUpWindow({action: "open"});
								var newIds=postIds.replace(allIds[i]+',', ""); 
								$("#hid_post_id").val(newIds);
								$("#hid_post_id_remove").val(allIds[i]);
								break;
							}
						}
				}else if(data.value==2){
					$('#notificationLoader').html('');
					var serchtodayPosts="";
					var view_p_detailes="";
					var obj = eval("(" + data.serchpost + ")");
					$.each(obj, function (index,Object) {
						var serchpostuserName=Object.user_name;
						serchpostuserName = serchpostuserName.toLowerCase().replace(/\b[a-z]/g, function(letter) {
							return letter.toUpperCase();
						});
						var serch_proposed_date_time=convertMysqldate(Object.proposed_date_time);
						var serch_until_date_time=convertMysqldate(Object.until_date_time);
						serchtodayPosts+='<div id="today-post'+Object.user_post_id+'">'+
						'<div class="viewlist_pad">'+
							'<div class="pos_relative">'+
								'<div class="view_list"><p>'+Object.phone+' '+serchpostuserName+'</p>'+
								'<p>'+Object.pincode+' '+Object.address+'</p>'+
								'<p>'+serch_proposed_date_time+' To  '+serch_until_date_time+'</p></div>'+
								'<div class="arrow1"></div>'+
								'<div class="arrow"></div>'+
								'<a href="javascript:void(0);"><div class="conform_btn_blue"><p>&#10004;</p></div></a>'+
							'</div>'+
						'</div>'+
					'</div>';
						var serch_user_post_id=Object.user_post_id;
						var serchalertobj = eval("(" + data.serchalerts + ")");
						$.each(serchalertobj, function (index,salerts) {
							if(index==serch_user_post_id){
								$.each(salerts, function (index,salertss) {
									if(salertss.status==0){
										var class_color='left_conform_btn_red';
									}else{
										var class_color='left_conform_btn';
									}
									var serchpartnerName=salertss.partner_name;
									serchpartnerName = serchpartnerName.toLowerCase().replace(/\b[a-z]/g, function(letter) {
										return letter.toUpperCase();
									});
									serchtodayPosts+='<input type="hidden" id="partnerName'+salertss.user_post_replies_id+'" name="partnerName'+salertss.user_post_replies_id+'" value="'+serchpartnerName+'">';
									serchtodayPosts+='<div class="viewlist_mar_t" id="todatAlerts'+salertss.user_post_replies_id+'">'+
									'<div class="viewlist_pad pos_relative">'+
										'<div class="pos_relative">'+
											'<div class="view_list_right"><p>'+salertss.partner_phone+' <a href="javascript:void(0);" onclick="serchaletspartDet('+salertss.user_post_replies_id+')">'+serchpartnerName+' </a></p>'+
											'<p> '+salertss.partner_pincode+' '+salertss.partner_address+'</p>'+
											'<p>'+serch_proposed_date_time+' To  '+serch_until_date_time+'</p></div>'+
											'<div class="arrow_left_move"><div class="arrow1"></div>'+
											'<div class="arrow"></div></div>';
											if(salertss.status==0){
												serchtodayPosts+='<a id="open-pop-up-2'+salertss.user_post_replies_id+'" href="#pop-up-1" onclick="openPopup('+salertss.user_post_replies_id+','+Object.user_post_id+')"><div class="'+class_color+'"><p>&#10004;</p></div></a>';
											}else{
												serchtodayPosts+='<a href="javascript:void(0);"><div class="'+class_color+'"><p>&#10004;</p></div></a>';
											}
										serchtodayPosts+='</div>'+
									'</div>'+
								'</div>';
								view_p_detailes+='<div id="spatid'+salertss.user_post_replies_id+'" class="popup_text">'+
								'<p><h4>Partner Detailes</h4></p>'+ 
								'<div class="input_field input_popup_t">'+
									'<table><tr><td>PartnerName</td><td>:</td><td>'+serchpartnerName+'</td></tr>' +
									'<tr><td>PhoneNumber</td><td>:</td><td>'+salertss.partner_phone+'</td></tr>' +
									'<tr><td>Address</td><td>:</td><td>'+salertss.partner_address+'</td></tr>' +
									'<tr><td>Pincode</td><td>:</td><td>'+salertss.partner_pincode+'</td></tr>' +
									'<tr><td>Proposed date</td><td>:</td><td>'+serch_proposed_date_time+'</td></tr>' +
									'<tr><td>Until date</td><td>:</td><td>'+serch_until_date_time+'</td></tr></table>' +
								'</div></tr>'+
								'</div>';
								});
							}
						});
						$("#today_lists").html("");
						$('#today_posts').html(serchtodayPosts);				
						$('#s_pat_det').html(view_p_detailes);				
					});	
				}else{
					$('#notificationLoader').html('');
					$('#today_posts').html('');
					$("#today_lists").html("NOT FOUND!");
				}
			}
		});
	}
}

//serchPDetailes popup_text
function serchPDetailes(userpostId){
	$('#serchpatid'+userpostId).popUpWindow({action: "open"});
}
function serchaletspartDet(userpostreplyId){
	$('#spatid'+userpostreplyId).popUpWindow({action: "open"});
}
